<template>
  <div>
    <button @click="getCar">get Car</button>
    <button @click="getStudents">get Students</button>
  </div>
</template>

<script>
import axios from 'axios'
export default {
    name:'App',
    methods:{
        async getCar(){
            let {data} = await axios.get('/che/cars')
            // /cars ==> localhost:8080/cars ==> 404 ==> http://localhost:5001/cars
            console.log('cars: ', data)
        },
        async getStudents(){
            let {data} = await axios.get('/xuesheng/students')
            console.log('students: ', data)
        }
    }
}
</script>

<style>
</style>